package com.meiyue.config.filter;

import com.meiyue.library.utils.MsgUtils;

import javax.servlet.*;
import java.io.IOException;

/**
 * MeiyueJavaProject
 * com.meiyue.config.filter
 * Created by Chris Chen
 * 2017/9/16
 * Explain:自定义过滤器
 */
//@WebFilter(urlPatterns = "/*")
public class CustomFilter implements Filter {
    @Override
    public void init(FilterConfig filterConfig) throws ServletException {

    }

    @Override
    public void doFilter(ServletRequest servletRequest, ServletResponse servletResponse, FilterChain filterChain) throws IOException, ServletException {
        MsgUtils.println("自定义过滤器->doFilter");
        filterChain.doFilter(servletRequest, servletResponse);
    }

    @Override
    public void destroy() {

    }
}
